class Man:

    def __init__(self, name, age, score):
        self.name = name
        self.__age = age
        self.__score = score

    @property
    def age(self):
        return self.__age

    @age.setter
    def age(self, age):
        self.__age = age

    def __str__(self):
        return "姓名:{},年龄{},分数{}".format(self.name, self.__age, self.__score)


a = Man("张三", 30, 100)
# print(a)
# a.set_age(20)
# print(a)
# print(a.get_age())
# print(dir(a))
print(a.age)
a.age = 20
print(a.age)
